package com.nbcio.iot.domain.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.nbcio.common.mybatis.core.domain.BaseEntity;

import jakarta.validation.constraints.NotBlank;
import lombok.Data;
import lombok.EqualsAndHashCode;


/**
 * 设备分组
 */
@Data
@EqualsAndHashCode(callSuper = true)
@TableName("iot_device_group")
public class IotDeviceGroup extends BaseEntity {

    @TableId(value = "group_id", type = IdType.ASSIGN_ID)
    private Long groupId;

    @NotBlank(message = "分组名称不能为空")
    @TableField("group_name")
    private String groupName;

    @TableField("parent_id")
    private Long parentId;

    @TableField("description")
    private String description;

    @TableField("order_num")
    private Integer orderNum;

    @TableField("status")
    private String status;
} 